#!/bin/bash

cd /root/kube_addons_src/calico/scripts

calico_version=v3.9
POD_CIDR="10.244.0.0/16"
wget https://docs.projectcalico.org/${calico_version}/manifests/calico-typha.yaml
sed -i -e "s?192.168.0.0/16?$POD_CIDR?g" calico-typha.yaml
sed -i -e "s?replicas: 1?replicas: 3?g" calico-typha.yaml
kubectl apply -f calico-typha.yaml
